package org.deltaset.samples.library.domain;

import java.util.List;
import org.springframework.transaction.annotation.Transactional;

/**
 *
 * @author dmakariev
 */
public interface AnimalRepository {

    Long countAll();

    @Transactional
    void delete(Animal animal);

    @Transactional
    List<Animal> findAll(Integer firstResult, Integer maxResult);

    Animal findById(String id);

    @Transactional
    void save(Animal entity);

    Animal edit(Animal entity);

    Animal newEntity();
}
